package cn.kaguyaever.service.impl;

import cn.kaguyaever.dao.ProjectDao;
import cn.kaguyaever.dao.impl.ProjectDaoImpl;
import cn.kaguyaever.entity.Project;
import cn.kaguyaever.service.ProjectService;

import java.util.List;

public class ProjectServiceImpl implements ProjectService {

    private ProjectDao projectDao = new ProjectDaoImpl();

    public void createProject(Project project){
        projectDao.createProject(project);
    }

    public void setCount(Integer count,String projectId){
        projectDao.setCount(count,projectId);
    }

    public Project queryProject(String projectId){return projectDao.queryProjectByProjectId(projectId);}

    public Project queryProjectByUserId(Integer userId){
        return projectDao.queryProjectByUserId(userId);
    }

    public void deleteProject(String projectId){projectDao.deleteProject(projectId);}
}

